var t = getApp(), e = t.requirejs('core');
Page({
    data: {
        member: {}
    },
    onShow() {
        let _this = this;
        e.get("member", {}, function(s) {
            _this.setData({member: s})
        });
    },
    logout() {
        wx.showModal({
            title: "提示",
            content: '确定退出登录吗?',
            success(res) {
                if(res.confirm) {
                    t.setCache("userinfo", ''), t.setCache("userinfo_openid", ''),
                    t.setCache("userinfo_id", '');
                    e.get("member/login/logout", {}, function(e) {})
                    wx.navigateTo({
                        url: "/pages/auth/login/index"
                    })
                }
            }
        })
    }
})